package com.jar.exercise.多线程.线程回调;

import java.util.function.Supplier;

/**
 * 懒加载
 */
public class Main {
    public static void main(String[] args) {
        lazyEvaluator(() -> true, () -> true);
    }

    public static void lazyEvaluator(final Supplier<Boolean> input1, final Supplier<Boolean> input2){
        System.out.println("lazyEvaluator called...");
        System.out.println("accept?: " + (input1.get() && input2.get()));
    }
}
